<?php
include_once 'head.phtml';
?>

<body>

<?php
include_once ('topbar.phtml');
?>

<div class="content">

<?php
include_once ('sidebar.phtml');
?>

  <div class="mcontent">

<table id="companydis" width="770px">
	<caption><span class="cotitle"><?php
	echo $this->getResult ( $this->conameSection );
	?></span>的优惠信息</caption>
	<tr>
		<th class="id">编号</th>
		<th class="img">优惠劵</th>
		<th class="info">优惠项目</th>
		<th class="date">截止日期</th>
		<th class="act">打印</th>
	</tr>
<?php
if (count ( $this->discountSection ) > 0) {
	?>
	  
<?php
	$i = 1;
	foreach ( $this->discountSection as $value ) {
		?>
	  <tr class="<?php
		echo $i % 2 == 0 ? "rowoff" : "rowon";
		?>">
		<td><?=$i;?></td>
		<td><?php
		echo "<img src='" . $value ['dispicpath'] . "' title='" . $this->getResult ( $value ['disbrief1'] ) . "'/>";
		?></td>
		<td><?php
		echo $this->getResult ( $value ['disdetail'] );
		?></td>
		<td><?php
		echo $this->getResult ( $value ['disedate'] );
		?></td>
		<td><input type="button" value="打印" id="button<?=$value ['id'];?>"
			onclick="window.location='/index/printdis/id/<?=$value ['id'];?>'" /></td>
	</tr>
<?php
		$i ++;
	}
	?>
	
<?php
} else
	?>
	  <tr>
		<td colspan="5"><?php
		echo $this->msgSection;
		?></td>
	</tr>
</table>

</div>
<!--end mcontent div--></div>
<!--end content div-->


<?php include_once 'foot.phtml'; ?>
